﻿using Little.Soldier.SWIFT;
using Little.Soldier.SWIFT.Definition;
using System.ComponentModel;

namespace Little.Soldier.SWIFT.Messages.Category0
{
  public class MT075 : SwiftMessage
  {
    private static SwiftMessageDefinition MessageDefinition;
    private static SwiftTagDefinition U0002;
    private static SwiftTagSubItemDefinition U0003;
    private static SwiftTagSubItemDefinition U0004;
    private static SwiftTagSubItemDefinition U0005;
    private static SwiftTagSubItemDefinition U0006;
    private static SwiftTagSubItemDefinition U0007;
    private static SwiftTagSubItemDefinition U0008;
    private static SwiftTagSubItemDefinition U000E;
    private static SwiftTagSubItemDefinition U000F;
    private static SwiftTagSubItemDefinition U0010;
    private static SwiftTagSubItemDefinition U0011;
    private static SwiftTagSubItemDefinition U0012;
    private static SwiftTagSubItemDefinition U0013;
    private static SwiftTagSubItemDefinition U0014;
    private static SwiftTagSubItemDefinition U0015;
    private static SwiftTagSubItemDefinition U0016;
    private static SwiftTagSubItemDefinition U0017;
    private static SwiftTagSubItemDefinition U0018;
    private static SwiftTagSubItemDefinition U0019;

    [Description("Request for Certification Cryptographic Service Message.")]
    public Tag604 CSMOfClassRFC_604
    {
      get
      {
        return new Tag604((SwiftElement) this, 0, (SwiftDefinitionElement) MT075.U0002);
      }
    }

    [Description("Request for Certification Cryptographic Service Message.")]
    public Tag604 Tag604_CSMOfClassRFC
    {
      get
      {
        return this.CSMOfClassRFC_604;
      }
    }

    public MT075()
      : base(true)
    {
    }

    public MT075(SwiftMessage message)
      : base(message)
    {
    }

    internal override SwiftMessageDefinition MsgDefinition()
    {
      return MT075.MessageDefinition;
    }

    protected override void InitSwiftMessageDefinition()
    {
      MT075.MessageDefinition = new SwiftMessageDefinition("MT075", "Request for Certification Cryptographic Service Message");
      MT075.U0002 = new SwiftTagDefinition("CSMOfClassRFC_604", "Request for Certification Cryptographic Service Message.");
      MT075.U0002.TagName = "{604:";
      MT075.U0003 = new SwiftTagSubItemDefinition("CSMOfClassRFC1", "CSM Message identifier and class");
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0003);
      MT075.U0004 = new SwiftTagSubItemDefinition("CSMOfClassRFC2", "Receiver specification");
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0004);
      MT075.U0005 = new SwiftTagSubItemDefinition("CSMOfClassRFC3", "Originator specification");
      MT075.U0006 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0005.Elements.Add((SwiftDefinitionElement) MT075.U0006);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0005);
      MT075.U0007 = new SwiftTagSubItemDefinition("CSMOfClassRFC4", "Requested CV expiry date");
      MT075.U0008 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0007.Elements.Add((SwiftDefinitionElement) MT075.U0008);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0007);
      MT075.U000E = new SwiftTagSubItemDefinition("CSMOfClassRFC5", "Public RSA Key of user");
      MT075.U000F = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U000E.Elements.Add((SwiftDefinitionElement) MT075.U000F);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U000E);
      MT075.U0010 = new SwiftTagSubItemDefinition("CSMOfClassRFC6", "PKS version");
      MT075.U0010.Mandatory = false;
      MT075.U0011 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0010.Elements.Add((SwiftDefinitionElement) MT075.U0011);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0010);
      MT075.U0012 = new SwiftTagSubItemDefinition("CSMOfClassRFC7", "Constant value");
      MT075.U0013 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0012.Elements.Add((SwiftDefinitionElement) MT075.U0013);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0012);
      MT075.U0014 = new SwiftTagSubItemDefinition("CSMOfClassRFC8", "SCR number");
      MT075.U0015 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0014.Elements.Add((SwiftDefinitionElement) MT075.U0015);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0014);
      MT075.U0016 = new SwiftTagSubItemDefinition("CSMOfClassRFC9", "S.W.I..F.T Card number (of UKMO ICC)");
      MT075.U0017 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0016.Elements.Add((SwiftDefinitionElement) MT075.U0017);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0016);
      MT075.U0018 = new SwiftTagSubItemDefinition("CSMOfClassRFC10", "CSM MAC (and closing delimiter)");
      MT075.U0019 = new SwiftTagSubItemDefinition("Request", "Request");
      MT075.U0018.Elements.Add((SwiftDefinitionElement) MT075.U0019);
      MT075.U0002.Elements.Add((SwiftDefinitionElement) MT075.U0018);
      MT075.MessageDefinition.Elements.Add((SwiftDefinitionElement) MT075.U0002);
    }
  }
}
